package com.example.netty.listenner;

import javax.annotation.Resource;

import org.springframework.boot.ApplicationArguments;
import org.springframework.boot.ApplicationRunner;
import org.springframework.stereotype.Component;

import com.example.netty.server.NettyServer;

/**
 * @Title: NettyStartListenner.java
 * @Package com.example.netty.listenner
 * @Description netty 启动类
 * @author feina
 * @date 2023/4/23 13:19
 * @Copyright
 */

@Component
public class NettyStartListenner implements ApplicationRunner {

    @Resource
    private NettyServer nettyServer;

    @Override
    public void run(ApplicationArguments args) throws Exception {
        nettyServer.start();
    }
}
